.depot_form
  = form_for @user do |f|
    - if @user.errors.any?
      #error_explanation
        %h2= "#{pluralize(@user.errors.count, "error")} prohibited this user from being saved:"
        %ul
          - @user.errors.full_messages.each do |msg|
            %li= msg
    %fieldset
      %legend Enter User Details

      .field
        = f.label :name, 'Name:'
        = f.text_field :name,size: 40
      - if params[:action]=='edit' || params[:action]=='update'
        .field
          = f.label :current_password, 'oldPassword:'
          = f.password_field :current_password,size: 40
      .field
        = f.label :password, 'Password:'
        = f.password_field :password,size: 40
      .field
        = f.label :password_confirmation,'Confirm:'
        = f.password_field :password_confirmation,size: 40
      .actions
        = f.submit 'Save'
